﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using ZLDC.Topo.BLL.Estate;
using System.Data;
using System.Text;
using ZLDC.Common.Estate;

namespace ZLDC.Estate.TM
{
    public partial class ShowChangeRooms : _PageBase
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                RoomNoBLL rbll = new RoomNoBLL();
                //根据栋阁编号去栋阁名称
                int bid = _Request.GetInt("id", 0);
                DataSet ds = rbll.SelectNameByBid(bid);
                string bname = "";
                if (ds != null)
                {
                     bname = ds.Tables[0].Rows[0]["finalName"].ToString();
                    //跟进栋阁编号取最大的楼层数
                }
                txtEsate.Value = bname;
                string floor = rbll.SelectMaxFloorByBid(bid).ToString();
                StringBuilder sb = new StringBuilder();
                sb.Append("<table id='tableList1' width='100%' border='0' cellpadding='0' cellspacing='1' bgcolor='#CCCCCC'>");
                //sb.Append("  <tr>");
                //sb.Append("   <td height='25' bgcolor='FFFFFF'>");
                //sb.Append("栋阁名称：<input id='txtEsate' name='txtEsate' type='text'  value='" + bname + "' readonly  class='textstyle1' style='width: 30%' />&nbsp;&nbsp;&nbsp;</br>");
                //sb.Append("   </td>");
                //sb.Append("</tr>");
                sb.Append("  <tr>");
                sb.Append("   <td height='25' bgcolor='FFFFFF'>");
                sb.Append("     <table><tr><td style=\"background-color:#FF99FF; width:50px; height:\"></td>");
                sb.Append("     <td>正在出售&nbsp;&nbsp;</td>");
                sb.Append("     <td style=\"background-color:Yellow; width:50px; height:\"></td>");
                sb.Append("     <td>正在出租&nbsp;&nbsp;</td>");
                sb.Append("     <td style=\"background-color:#66CCFF; width:50px; height:\"></td>");
                sb.Append("     <td>即租又售&nbsp;&nbsp;&nbsp;&nbsp;</td>");
                sb.Append("     <td>无背景色表示未放盘源</td>");
                sb.Append("     </tr></table>");
                sb.Append("   </td>");
                sb.Append("</tr>");
                sb.Append("</table>");
                sb.Append("<div id='divList' style='text-align:center'>");
                sb.Append("<table id='tableList2' width='100%' border='0' cellpadding='0' cellspacing='1' bgcolor='#CCCCCC'>");
                sb.Append("  <tr>");
                sb.Append("    <td height='10' bgcolor='FFFFFF'>");
                sb.Append("      <div align='center'>");
                sb.Append("           <span class='STYLE10'>楼层</span></div>");
                sb.Append("    </td>");
                sb.Append("   <td height='10' bgcolor='FFFFFF'>");
                sb.Append("      <div align='center'>");
                sb.Append("          <span class='STYLE10'>用途</span></div>");
                sb.Append("   </td>");
                sb.Append(" </tr>");
                sb.Append(" </table>");
                sb.Append("</div>");
                ltDiv.Text = sb.ToString();
            }
        }

        
    }
}

        
    
